<!doctype html>
<html lang="ru">

<head>
    <!--Import css-->
    <link type="text/css" rel="stylesheet" href="{{ url_for('static', filename='css/spectre.min.css') }}" />
    <link type="text/css" rel="stylesheet" href="{{ url_for('static', filename='css/spectre-exp.min.css') }}" />
    <link type="text/css" rel="stylesheet" href="{{ url_for('static', filename='css/spectre-icons.min.css') }}" />
    <!--Let browser know website is optimized for mobile-->
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <meta charset="utf-8">
    <title>Url Shortcuts - короткие ярлыки для длинных ссылок</title>
</head>

<body>
    <div class="container grid-md">
        
        {% block navbar %}
        <header class="navbar">
            <section class="navbar-section">
                <div class="input-group input-inline">
                    <a href="https://github.com/silentmode0n/url_shortcuts" class="btn btn-link">GitHub</a>
                    
                </div>
            </section>

            <section class="navbar-center">
                <a href="{{ url_for('index') }}" class="navbar-brand text-bold mr-2">Url Shortcuts</a>
            </section>

            <section class="navbar-section">
                {% if current_user.is_authenticated %}
                    <div class="dropdown">
                        <a href="#" class="btn btn-link dropdown-toggle" tabindex="0">
                        {{ current_user.name }} <i class="icon icon-caret"></i>
                        </a>
                        <ul class="menu">
                            <a href="{{ url_for('logout') }}" class="btn btn-link">Выйти</a>
                        </ul>
                  </div>
                {% else %}
                    <a href="{{ url_for('login') }}" class="btn btn-link">Войти</a>
                {% endif %}
            </section>
        </header>
        {% endblock %}

        {% block flash %}
        <div id="flash" class="column">
            {% for category, message in get_flashed_messages(with_categories=True) %}
            <div class="{{ category }}">
                {{ message }}
            </div>
            {% endfor %}
        </div>
        {% endblock %}

        {% block content %} {% endblock %}

    </div>
    <script src="{{ url_for('static', filename='js/flash.js') }}"></script>
</body>

</html>